<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>留言板</title>
    <link rel="stylesheet" href="../static/main.css" type="text/css"> <!--添加link标签 -->
</head>
<body>
    <h1>留言板</h1>
    <form action="/post" method="post">
        <p>请留言</p>
        <table>
            <tr>
                <th>名字</th>
                <td>
                    <input type="text" size="20" name="name">
                </td>
            </tr>
            <tr>
                <th>留言</th>
                <td>
                    <textarea rows="5" cols="40" name="comment"></textarea>
                </td>
            </tr>
        </table>
        <p><button type="submit">提交</button></p>
    </form>
    <div class="entries-area"> <!-- 在div标签中添加class属性 -->
        <h2>留言记录</h2>
        {%  for greeting in greeting_list %}
            <h3>{{ greeting.name }}
                的留言({{ greeting.create_at|datetime_fmt }}):</h3>
            <p>{{ greeting.comment|n12br }}</p>
        {%  endfor %}
    </div>
</body>
</html>